home *** CD-ROM | disk | FTP | other *** search
/ Utilities Professional 1-1500 / Utilities Professional 1-1500 (1994)(WPD)[!].iso / 12511500 / var1481.dms / var1481.adf / Extract_Me.LHA / misc / turbo.h < prev    next >
C/C++ Source or Header  |  1994-07-07  |  3KB  |  238 lines

  1. #ifdef AMIGA
  2. #include <Exec/Types.h>
  3. #else
  4. typedef long int LONG;
  5. typedef unsigned char UBYTE;
  6. typedef unsigned short UWORD;
  7. typedef char BYTE;
  8. typedef short WORD;
  9. #endif
  10.  
  11. typedef LONG    FRACT;
  12. typedef UBYTE    COLOR[3];
  13.  
  14. typedef struct vectors {
  15.     FRACT    X;
  16.     FRACT    Y;
  17.     FRACT    Z;
  18. } VECTOR;
  19.  
  20. typedef struct matrices {
  21.     VECTOR    I;
  22.     VECTOR    J;
  23.     VECTOR    K;
  24. } MATRIX;
  25.  
  26. typedef struct story {
  27.     UBYTE    Path[18];
  28.     VECTOR    Translate;
  29.     VECTOR    Rotate;
  30.     VECTOR    Scale;
  31.     UWORD    info;
  32. } STORY;
  33.  
  34. #define ABS_TRA        0x0001
  35. #define ABS_ROT        0x0002
  36. #define ABS_SCL        0x0004
  37. #define LOC_TRA        0x0010
  38. #define LOC_ROT        0x0020
  39. #define LOC_SCL        0x0040
  40. #define X_ALIGN        0x0100
  41. #define Y_ALIGN        0x0200
  42. #define Z_ALIGN        0x0400
  43. #define FOLLOW_ME    0x1000
  44.  
  45.  
  46. typedef struct {
  47.     WORD    Number;
  48.     BYTE    Filename[80];
  49. } BRSH;
  50.  
  51. typedef BRSH    STNC;
  52.  
  53. typedef BRSH    TXTR;
  54.  
  55. typedef struct {
  56.     VECTOR    Camera;
  57.     VECTOR    Rotate;
  58.     FRACT    Focal;
  59. } OBSV;
  60.  
  61. typedef struct {
  62.     BYTE    Trackname[18];
  63. } OTRK;
  64.  
  65. typedef struct {
  66.     STORY    CStory;
  67. } OSTR;
  68.  
  69. typedef struct {
  70.     FRACT    FadeAt;
  71.     FRACT    FadeBy;
  72.     BYTE    pad;
  73.     COLOR    FadeTo;
  74. } FADE;
  75.  
  76. typedef struct {
  77.     BYTE    pad;
  78.     COLOR    Horizon;
  79.     BYTE    pad2;
  80.     COLOR    Zenith;
  81. } SKYC;
  82.  
  83. typedef struct {
  84.     BYTE    pad;
  85.     COLOR    Ambient;
  86. } AMBI;
  87.  
  88. typedef struct {
  89.     BYTE    Props[8];
  90. } GLB0;
  91.  
  92. #define GLB_EDGING        0
  93. #define GLB_PERTURB        1
  94. #define GLB_SKY_BLEND    2
  95. #define GLB_LENS        3
  96. #define GLB_FADE        4
  97. #define GLB_SIZE        5
  98. #define GLB_RESOLVE        6
  99. #define GLB_EXTRA        7
  100.  
  101. typedef struct {
  102.     BYTE    Name[18];
  103. } NAME;
  104.  
  105. typedef struct {
  106.     WORD    Shape;
  107.     WORD    Lamp;
  108. } SHAP;
  109.  
  110. #define LMP_NOTALAMP    0
  111. #define LMP_SUN            1
  112. #define LMP_LAMP        2
  113.  
  114. #define SHP_SPHERE        0
  115. #define SHP_STENCIL        1
  116. #define SHP_AXIS        2
  117. #define SHP_FACETS        3
  118. #define SHP_SURFACE        4
  119. #define SHP_GROUND        5
  120.  
  121. typedef struct {
  122.     VECTOR    Position;
  123. } POSI;
  124.  
  125. typedef struct {
  126.     VECTOR    XAxis;
  127.     VECTOR    YAxis;
  128.     VECTOR    ZAxis;
  129. } AXIS;
  130.  
  131. typedef struct {
  132.     VECTOR    Size;
  133. } SIZE;
  134.  
  135. typedef struct {
  136.     UWORD    PCount;
  137.     VECTOR    Points[1];
  138. } PNTS;
  139.  
  140. typedef struct {
  141.     UWORD    ECount;
  142.     UWORD    Edges[1][2];
  143. } EDGE;
  144.  
  145. typedef struct {
  146.     UWORD    TCount;
  147.     UWORD    Connects[1][3];
  148. } FACE;
  149.  
  150. typedef struct {
  151.     BYTE    pad;
  152.     COLOR    col;
  153. } COLR, REFL, TRAN, SPC1;
  154.  
  155. typedef struct {
  156.     UWORD    count;
  157.     COLOR    colors[1];
  158. } CLST, RLST, TLST;
  159.  
  160. typedef struct {
  161.     FRACT    Params[16];
  162. } TPAR;
  163.  
  164. typedef struct {
  165.     BYTE    SProps[5];
  166. } SURF;
  167.  
  168. #define PRP_SURFACE    0
  169. #define PRP_BRUSH    1
  170. #define PRP_WRAP    2
  171. #define PRP_STENCIL    3
  172. #define PRP_TEXTURE    4
  173.  
  174. typedef struct {
  175.     UBYTE    Type;
  176.     UBYTE    Index;
  177. } MTTR;
  178.  
  179. #define RFR_AIR        0
  180. #define RFR_WATER    1
  181. #define RFR_GLASS    2
  182. #define RFR_CRYSTAL    3
  183. #define RFR_CUSTOM    4
  184.  
  185. #define VAL_AIR        1.00
  186. #define VAL_WATER    1.33
  187. #define VAL_GLASS    1.67
  188. #define VAL_CRYSTAL    2.00
  189.  
  190. #define VAL_CUSTOM(v)    (((v)/100.0)+1.0)
  191.  
  192. typedef struct {
  193.     UBYTE    Specularity;
  194.     UBYTE    Hardness;
  195. } SPEC;
  196.  
  197. typedef struct {
  198.     UBYTE    Props[6];
  199. } PRP0;
  200.  
  201. #define PRP_BLEND    0
  202. #define PRP_SMOOTH    1
  203. #define PRP_SHADE    2
  204. #define PRP_PHONG    3
  205. #define PRP_GLOSSY    4
  206. #define PRP_QUICK    5
  207.  
  208. typedef struct {
  209.     UBYTE    Props[8];
  210. } PRP1;
  211.  
  212. #define PRP1_DITHER    0
  213. #define PRP1_HARD    1
  214. #define PRP1_ROUGH    2
  215. #define PRP1_SHINY    3
  216. #define PRP1_INDEX    4
  217. #define PRP1_QUICK    5
  218. #define PRP1_PHONG    6
  219. #define PRP1_GENLOCK    7
  220.  
  221. typedef struct {
  222.     FRACT    Intensity;
  223. } INTS;
  224.  
  225. typedef struct {
  226.     STORY    Story;
  227. } STRY;
  228.  
  229. typedef struct {
  230.     VECTOR    Translate;
  231.     VECTOR    Scale;
  232.     MATRIX    Rotate;
  233. } MTRX;
  234.  
  235. typedef struct {
  236.     BYTE    Filename[80];
  237. } LOAD;
  238.